function aboutUsMenu($){

	var container = null;

	return {
		// 关于我们左侧menu
		init: function(container){
			var _this = this;

			var index = _this.urlParam(location.href, "index");
			_this.gen(container,index); // menu 加载
			_this.bindAboutUsMenuEvents(); // menu事件绑定
		},
		// 关于我们左侧导航菜单
		gen:function(container, index){
			var htmlStr = "", _this = this;
			htmlStr = htmlStr + '<div class="helpmenu" id="helpmenu">'
			+ '<div class="vertical-nav">'
			+ '<div><a href="javascript:void(0)" class="helpTitle mainT helphead none" index="1"  id="helpCenter">帮助中心</a></div>'
			+ '<div class="helpTitle mainT none">新手必读</div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="2"  id="companyProfile">公司简介</a></div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="3"  id="hostedPublicity">托管公示</a></div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="4" id="riskWarning">风险提示</a></div>'
			+ '<div class="helpTitle mainT none">常见问题</div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="5"  id="helpDetail">账户安全</a></div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="6"  id="accountManagement">账户管理</a></div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="7"  id="rechargeCash">充值提现</a></div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="8"  id="investmentPayment">投资支付</a></div>'
			+ '<div class="helpTitle mainT none">小知识</div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="9"  id="termExplanation">名词解释</a></div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="10"  id="helpCoupon">优惠券</a></div>'
			+ '<div class="helpTitle mainT none">流程指引</div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="11"  id="processCertification">开户认证</a></div>'
			+ '<div><a href="javascript:void(0)" class="helpTitle" index="12"  id="processHy">投资汇银汇企</a></div>'
			+ '</div>'
			+ '</div>'
			$(container).html("").html(htmlStr);

			$(".helpTitle").each(function(){
				$(this).removeClass("current");
				if ($(this).attr("index") == index) {$(this).addClass("current");};
			});

		},
		// 导航菜单链接
		bindAboutUsMenuEvents:function(){
			var _this = this;
			// 帮助中心
			$("#helpCenter").on("click",function(){
				_this.windowJump("../help/helpCenter.html?index=1");
			});
			// 公司简介
			$("#companyProfile").on("click",function(){
				_this.windowJump("../help/companyProfile.html?index=2");
			});
			// 托管公示
			$("#hostedPublicity").on("click",function(){
				_this.windowJump("../help/hostedPublicity.html?index=3");
			});
			// 风险提示
			$("#riskWarning").on("click",function(){
				_this.windowJump("../help/riskWarning.html?index=4");
			});
			// 账户安全
			$("#helpDetail").on("click",function(){
				_this.windowJump("../help/helpDetail.html?index=5");
			});
			// 账户管理
			$("#accountManagement").on("click",function(){
				_this.windowJump("../help/accountManagement.html?index=6");
			});
			// 充值提现
			$("#rechargeCash").on("click",function(){
				_this.windowJump("../help/rechargeCash.html?index=7");
			});
			// 投资支付
			$("#investmentPayment").on("click",function(){
				_this.windowJump("../help/investmentPayment.html?index=8");
			});
			//名词解释
			$("#termExplanation").on("click",function(){
				_this.windowJump("../help/termExplanation.html?index=9");
			});
			//优惠券
			$("#helpCoupon").on("click",function(){
				_this.windowJump("../help/helpCoupon.html?index=10");
			});
			//开户认证
			$("#processCertification").on("click",function(){
				_this.windowJump("../help/processCertification.html?index=11");
			});
			//投资汇银汇企
			$("#processHy").on("click",function(){
				_this.windowJump("../help/processHy.html?index=12");
			});
		},
		//window 跳转
		windowJump :function(url, isReplaceUrl) {
			if (!url) url = "/";
			if (isReplaceUrl) {
				window.location.replace(url);
			} else {
				window.location.href = url;
			}
		},
		
		// url参数
		urlParam :function(url, param) {
			var pattern = new RegExp("[?&]" + param + "\=([^&]+)", "g");
			var matcher = pattern.exec(url);
			var items = "";
			if (null !== matcher) {
				try {
					items = decodeURIComponent(decodeURIComponent(matcher[1])); 
				} catch(e) {
					try {
						items = decodeURIComponent(matcher[1]);
					} catch(e) {
						items = matcher[1];
					}
				}
			}
			if (items) {
				items = items.indexOf("#") > 0 ? items.substr(0, items.indexOf("#")) : items;
			}
			return items;
		}
	}
}

if("function"==typeof define && define.amd && define){
	define(['jquery'],function($){
		return aboutUsMenu($);
	});
}